import type { App } from 'vue'
import { createPinia } from 'pinia'
import { piniaPersistedstate } from './persist'

export const pinia = createPinia()

pinia.use(piniaPersistedstate) // 使用持久化插件

export function setupStore(app: App<Element>) {
  app.use(pinia)
}
